{% extends 'blog/base.html' %}

{% block content %}

<div>
  <h1>Title: {{ object.title }}</h1>

  <p>Body: {{ object.body }}</p>
  <p>Author: {{ object.author }}</p>
  <p>Date_created: {{ object.date_created }}</p>
  <p>Date modified: {{ object.date_modified }}</p>

  


  {% if post.author == request.user %}
  <form class="inline" action="{% url 'blog:edit' post.pk %}">
    {% csrf_token %}
    <button type="submit">Edit</button>
  </form>
  <form class="inline" method="POST" action="{% url 'blog:delete' post.pk %}">
      {% csrf_token %}
      <button type="submit">Delete</button>
  </form>
  {% endif %}
</div>


{% endblock %}
